import { Component } from '@angular/core';
import { NzIconModule } from 'ng-zorro-antd/icon';
import { NzInputModule } from 'ng-zorro-antd/input';
import { NzToolTipModule } from 'ng-zorro-antd/tooltip';

@Component({
  selector: 'app-input-presuffix',
  standalone: true,
  imports: [NzInputModule, NzIconModule, NzToolTipModule],
  template: `
    <div class="demo">
      <nz-input-group nzPrefixIcon="user" [nzSuffix]="userInfo">
        <input nz-input />
      </nz-input-group>
      <ng-template #userInfo>
        <span
          nz-icon
          nzType="info-circle"
          nz-tooltip
          nzTooltipTitle="输入用户名"
        ></span>
      </ng-template>
    </div>

    <div class="demo mt-4">
      <nz-input-group nzPrefix="￥" nzSuffix="RMB">
        <input nz-input />
      </nz-input-group>
    </div>
  `,
  styles: ``,
})
export class InputPresuffixComponent {}
